﻿<?php
include_once('connexpdo.php');
include_once ('fonctions.php');
$resultat =0;
$id = $_GET['id'];
$connexion = connexpdo();
$requete = ('SELECT ART_ID, ART_TITRE, ART_CONTENU,
DAY(ART_DATEDEBVALID) AS jour, MONTH(ART_DATEDEBVALID) AS mois, YEAR(ART_DATEDEBVALID) AS annee
FROM article WHERE ART_ID='.$id);
$requeteimage = ("SELECT * FROM article news INNER JOIN contenir AS c ON news.ART_ID = c.ID
		 INNER JOIN image AS i on c.ID_1 = i.IM_ID
		 INNER JOIN album AS al ON i.IM_ID_APPARTENIR = al.ALB_ID
		 WHERE ART_ID =".$id);
$resultatimage = $connexion->query($requeteimage);
$image = $resultatimage->fetch(PDO::FETCH_ASSOC);
$resultat = $connexion->query($requete);
$donnees = $resultat->fetch(PDO::FETCH_ASSOC)
?>
<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <!-- PAGE TITLE -->
    <title>ASPC Badminton</title>
    <!-- MAKE IT RESPONSIVE -->
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <!-- BOOTSTRAP -->
    <link href="css/bootstrap.min.css" rel="stylesheet" media="screen">
    <!-- MAIN STYLE -->
    <link href="css/customize.css" rel="stylesheet" media="screen">
    <link href="css/style.css" rel="stylesheet" media="screen">
   <!--           <link rel="stylesheet" type="text/css" href="css/demo.css" />
		<link rel="stylesheet" type="text/css" href="css/styles.css" />
		<link rel="stylesheet" type="text/css" href="css/elastislide.css" />
    -->
    		<link rel="stylesheet" type="text/css" href="css/elastislide.css" />
    				<link rel="stylesheet" type="text/css" href="css/styles.css" />
    				<link rel="stylesheet" type="text/css" href="css/demo.css" />
    <!-- FONTS -->
    <link href='http://fonts.googleapis.com/css?family=Lato:300,400,700' rel='stylesheet' type='text/css'>
    <link href='http://fonts.googleapis.com/css?family=Varela+Round' rel='stylesheet' type='text/css'>
    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="js/html5shiv.js"></script>
      <script src="js/respond.min.js"></script>
    <![endif]-->
  </head>
  <!-- START BODY -->
  <body>
	<div id="page">
		<!-- START MAIN CONTAINER -->
		<div id="main-container">
		<?php affiche_menu();?>
			<!-- START PAGE SECTION -->
			<section id="single-page" class="section with-arrow">
				<!-- SECTION TITLE -->
				<div class="section-header">
					<div class="container">
						<h1><?php echo $donnees['ART_TITRE'];?></h1>
					</div>
				</div>
				<!-- SECTION CONTENT -->
				<div class="section-content">
					<div class="container">
						<div class="row">
							<!-- POST CONTENT -->
							<div class="col-md-9">
							<?php if ($id != 30 ){?>
								<div class="post-featured">
								 <img src="<?php echo $image['ALB_URL'];echo $image['IM_FICHIER']?>" alt="Featured Image" style="max-width:100%;
									max-height:100%;">
							    </div>
							    <?php }?>
							    <div class="post-date">
								    <span><?php echo $donnees['jour'].' '.utf8_encode(changermois($donnees['mois'])).' 
								'.$donnees['annee'];?></span>
							    </div>
							    <div class="post-content">
								    <?php echo $donnees['ART_CONTENU'];
								    if ($id ==30){
										affiche_1album();
									}
								    ?>
								</div>
							    
							    
							</div>
							<!-- SIDEBAR CONTENT -->
							<div class="col-md-3">
								<!-- LATEST POST WIDGET -->
								 <ul class="social-list">
									<li><a href="https://www.facebook.com/groups/31973811026/?fref=ts" target="_blank" class="btn btn-facebook" style="font-size: 12px; width: 250px;"><span class="icon icon-dailymotion"><img src="images/gallery/facebook-icon.png"></span> Rejoignez nous sur Facebook</a></li>
									<li><a href="http://www.dailymotion.com/ASPC-BADMINTON" target="_blank" class="btn btn-twitter" style="font-size: 12px; width: 250px;" ><span class="icon icon-dailymotion"><img src="images/gallery/daily-icon.png"></span> Suivez nous sur Dailymotion </a></li>
								</ul>
								<!-- DONATION WIDGET -->
					            <div class="widget">
					              <h4 style="color: black; font-size: medium;">Vous souhaitez faire un don à L'ASPC Badminton ?</h4>
					              <a href="index.php#donation">(plus d'informations ici)</a>
					              <a href="https://www.paypal.com/fr/cgi-bin/webscr?cmd=_flow&SESSION=MVJsJFt5Z_DyNe3s4qm2Hm-bmtxTNpIf6vVlTyXgS3dG_f7zDg07h16G4Wq&dispatch=5885d80a13c0db1f8e263663d3faee8da8649a435e198e44a05ba053bc68d12e" class="btn btn-default widget-btn">Faites un don </a>
					            </div><!-- END .WIDGET -->

					           <!-- <div class="widget">
					            
									<h4 style="color: black; font-size: medium;">Les dernières news de la FFBAD (Liens cliquables !)</h4>
									<?php // affiche_rss();	?>
								</div>--><!-- END .WIDGET -->
					            <!-- ARCHIVES WIDGET -->
					            <!-- <div class="widget">
					              <h3>Archives</h3>
					              <ul class="list-icon">
					                <li><a href="#">October 2013</a></li>
					                <li><a href="#">September 2013</a></li>
					                <li><a href="#">August 2013</a></li>
					                <li><a href="#">July 2013</a></li>
					                <li><a href="#">June 2013</a></li>
					              </ul>
					            </div>--><!-- END .WIDGET -->

							</div>
						</div>
					</div>
				</div>
			</section>
			<!-- END TEAM SECTION -->
			
			<!-- START FOOTER SECTION -->
			<?php affiche_footer();?>
			<!-- END FOOTER SECTION -->
		
		</div>
		<!-- END MAIN CONTAINER -->
		
		<!-- PAGE LOADING-->
		<div id="loader"></div>
  	</div>
    <!-- SCRIPTS -->
<?php affiche_scripts();?>
  </body>
  <!-- END BODY -->
</html>
<?php 
?>